<include file="public@header"/>
</head>
<body>
<div class="layui-fluid js-check-wrap">
    <div class="layui-card">
        <div class="layui-card-header">
            <h3>{:lang('API_ADMINGUESTBOOK_INDEX')}</h3>
        </div>

        <div class="layui-card-body">
            <form class="form-search layui-form layui-form-item" action="{:url('AdminGuestbook/index')}">
                <div class="layui-inline">
                    <label class="layui-form-label">时间:</label>
                    <div class="layui-input-inline">
                        <input type="text" class="layui-input js-layui-datetime" name="start_time"
                           value="{$start_time|default=''}"
                           style="" autocomplete="off">
                    </div>
                    <div class="layui-form-mid">-</div>
                    <div class="layui-input-inline">
                        <input type="text" class="layui-input js-layui-datetime" name="end_time"
                               value="{$end_time|default=''}"
                               style="" autocomplete="off">
                    </div>
                </div>
                <div class="layui-inline">
                    <input type="submit" class="layui-btn layui-btn-normal" value="{:lang('SEARCH')}"/>
                </div>
                <div class="layui-inline">
                    <a class="layui-btn layui-btn-danger" href="{:url('AdminGuestbook/index')}">{:lang('EMPTY')}</a>
                </div>
            </form>
        </div>

        <form class="js-ajax-form" action="" method="post">
            <table class="layui-table" lay-skin="line">
                <thead>
                <tr>
                    <th class="text-center" width="20">
                        <div class="custom-checkbox">
                            <input type="checkbox" id="checkall" class="js-check-all" data-direction="x" data-checklist="js-check-x">
                            <label for="checkall"></label>
                        </div>
                    </th>
                    <th width="50">ID</th>
                    <th>{:lang('TITLE')}</th>
                    <th>{:lang('NAME')}</th>
                    <th>{:lang('EMAIL')}</th>
                    <th>{:lang('PHONE')}</th>
                    <th>{:lang('IP_ADDRESS')}</th>
                    <!-- <th>{:lang('CONTENT')}</th> -->
                    <th>{:lang('TIME')}</th>
                    <th>{:lang('ACTIONS')}</th>
                </tr>
                </thead>
                <foreach name="lists" item="vo">
                    <tr>
                        <td class="text-center">
                            <div class="custom-checkbox">
                                <input type="checkbox" class="js-check" data-yid="js-check-y" data-xid="js-check-x" name="ids[]" id="chk_{$vo.id}"
                                   value="{$vo.id}" title="ID:{$vo.id}">
                                <label for="chk_{$vo.id}"></label>
                            </div>
                        </td>
                        <td>{$vo.id}</td>
                        <td>{$vo.title|default="-"}</td>
                        <td>{$vo.full_name}</td>
                        <td>{$vo.email}</td>
                        <td>{$vo.phone}</td>
                        <td>{$vo.ip_address}</td>
                        <!-- <td>{$vo.msg|msubstr=###,0,30}</td> -->
                        <td width="150">{$vo.createtime}</td>
                        <td>
                            <a href="javascript:parent.openIframeLayer('{:url('AdminGuestbook/edit',array('id'=>$vo['id']))}','留言详情',{area:['80%', '80%']})" class="layui-btn layui-btn-xs">{:lang('LOOK')}</a>
                            <!-- <a href="{:url('AdminGuestbook/delete',array('id'=>$vo['id']))}" class="js-ajax-delete">{:lang('DELETE')}</a> -->
                        </td>
                    </tr>
                </foreach>
            </table>
            
            <div class="pagination-row clearfix">
                <div class="layui-col-sm2">
                    <!-- 删除选中项 -->
                    <button class="layui-btn layui-btn-danger layui-btn-md js-ajax-submit" type="submit"
                            data-action="{:url('AdminGuestbook/delete')}" data-subcheck="true" data-msg="您确定删除吗？">
                        {:lang('DELETE_SELECTED')}
                    </button>
                </div>
                <div class="pages">{$page|default=''}</div>
            </div>
        </form>
    </div>
</div>
<include file="public@footer"/>
